Optimal. Leaf size=47 \[ \log (x+1) (d-e+f-g)-\log (x+2) (d-2 e+4 f-8 g)+x (f-3 g)+\frac{g x^2}{2} \]
[Out]
_______________________________________________________________________________________
Rubi [A] time = 0.122068, antiderivative size = 47, normalized size of antiderivative = 1., number of steps used = 6, number of rules used = 4, integrand size = 36, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.111 \[ \log (x+1) (d-e+f-g)-\log (x+2) (d-2 e+4 f-8 g)+x (f-3 g)+\frac{g x^2}{2} \]
Antiderivative was successfully verified.
[In] Int[((2 - 3*x + x^2)*(d + e*x + f*x^2 + g*x^3))/(4 - 5*x^2 + x^4),x]
[Out]
_______________________________________________________________________________________
Rubi in Sympy [F] time = 0., size = 0, normalized size = 0. \[ - 3 g x + g \int x\, dx - \left (d - 2 e + 4 f - 8 g\right ) \log{\left (x + 2 \right )} + \left (d - e + f - g\right ) \log{\left (x + 1 \right )} + \int f\, dx \]
Verification of antiderivative is not currently implemented for this CAS.
[In] rubi_integrate((x**2-3*x+2)*(g*x**3+f*x**2+e*x+d)/(x**4-5*x**2+4),x)
[Out]
_______________________________________________________________________________________
Mathematica [A] time = 0.0413789, size = 44, normalized size = 0.94 \[ \log (x+1) (d-e+f-g)-\log (x+2) (d-2 e+4 f-8 g)+f x+\frac{1}{2} g (x-6) x \]
Antiderivative was successfully verified.
[In] Integrate[((2 - 3*x + x^2)*(d + e*x + f*x^2 + g*x^3))/(4 - 5*x^2 + x^4),x]
[Out]
_______________________________________________________________________________________
Maple [A] time = 0.009, size = 69, normalized size = 1.5 \[{\frac{g{x}^{2}}{2}}+fx-3\,gx-\ln \left ( 2+x \right ) d+2\,\ln \left ( 2+x \right ) e-4\,\ln \left ( 2+x \right ) f+8\,\ln \left ( 2+x \right ) g+\ln \left ( 1+x \right ) d-\ln \left ( 1+x \right ) e+\ln \left ( 1+x \right ) f-\ln \left ( 1+x \right ) g \]
Verification of antiderivative is not currently implemented for this CAS.
[In] int((x^2-3*x+2)*(g*x^3+f*x^2+e*x+d)/(x^4-5*x^2+4),x)
[Out]
_______________________________________________________________________________________
Maxima [A] time = 0.704417, size = 61, normalized size = 1.3 \[ \frac{1}{2} \, g x^{2} +{\left (f - 3 \, g\right )} x -{\left (d - 2 \, e + 4 \, f - 8 \, g\right )} \log \left (x + 2\right ) +{\left (d - e + f - g\right )} \log \left (x + 1\right ) \]
Verification of antiderivative is not currently implemented for this CAS.
[In] integrate((g*x^3 + f*x^2 + e*x + d)*(x^2 - 3*x + 2)/(x^4 - 5*x^2 + 4),x, algorithm="maxima")
[Out]
_______________________________________________________________________________________
Fricas [A] time = 0.255763, size = 61, normalized size = 1.3 \[ \frac{1}{2} \, g x^{2} +{\left (f - 3 \, g\right )} x -{\left (d - 2 \, e + 4 \, f - 8 \, g\right )} \log \left (x + 2\right ) +{\left (d - e + f - g\right )} \log \left (x + 1\right ) \]
Verification of antiderivative is not currently implemented for this CAS.
[In] integrate((g*x^3 + f*x^2 + e*x + d)*(x^2 - 3*x + 2)/(x^4 - 5*x^2 + 4),x, algorithm="fricas")
[Out]
_______________________________________________________________________________________
Sympy [A] time = 3.35304, size = 66, normalized size = 1.4 \[ \frac{g x^{2}}{2} + x \left (f - 3 g\right ) + \left (- d + 2 e - 4 f + 8 g\right ) \log{\left (x + \frac{4 d - 6 e + 10 f - 18 g}{2 d - 3 e + 5 f - 9 g} \right )} + \left (d - e + f - g\right ) \log{\left (x + 1 \right )} \]
Verification of antiderivative is not currently implemented for this CAS.
[In] integrate((x**2-3*x+2)*(g*x**3+f*x**2+e*x+d)/(x**4-5*x**2+4),x)
[Out]
_______________________________________________________________________________________
GIAC/XCAS [A] time = 0.286063, size = 66, normalized size = 1.4 \[ \frac{1}{2} \, g x^{2} + f x - 3 \, g x -{\left (d + 4 \, f - 8 \, g - 2 \, e\right )}{\rm ln}\left ({\left | x + 2 \right |}\right ) +{\left (d + f - g - e\right )}{\rm ln}\left ({\left | x + 1 \right |}\right ) \]
Verification of antiderivative is not currently implemented for this CAS.
[In] integrate((g*x^3 + f*x^2 + e*x + d)*(x^2 - 3*x + 2)/(x^4 - 5*x^2 + 4),x, algorithm="giac")
[Out]